<link rel="stylesheet" href="/static/admin/css/auth.css?v={$version}">
<div class="layui-card">
    <div class="layui-card-body">

        <form action=""  class="layui-form">
            <div class="layui-form-item">
                <div class="layui-input-inline">
                    <input type="text" name="keywords" value="{$search.keywords|default=''}" class="layui-input" placeholder="节点名称">
                </div>
                <div class="layui-input-inline">
                    <button class="layui-btn" lay-submit lay-filter="formDemo">搜索</button>
                    {if isset($search.keywords)}
                    <a href="javascript:history.go(-1);" class="layui-btn">返回</a>
                    {/if}
                </div>
            </div>
        </form>

        <div class="layui-btn-group">
            <button data-url="{:url('admin/system.node/addnode')}" class="layui-btn layui-btn-xs ref-node">
                <i class="layui-icon  layui-icon-release"></i>
                导入节点
            </button>

            <button data-url="{:url('admin/system.node/refnode')}" class="layui-btn layui-btn-xs ref-node">
                <i class="layui-icon layui-icon-refresh "></i>
                更新节点
            </button>

            <button data-url="{:url('admin/system.node/clearExceptionNode')}" class="layui-btn layui-btn-xs layui-btn-danger clearExceptionNode">
                <i class="layui-icon">&#xe640;</i>
                清楚异常节点
            </button>
        </div>

        <div>
            <form action="" class="layui-form">
                <table class="layui-table">
                    <thead>
                    <tr>
                        <th width="40">状态</th>
                        <th width="60">是否视图</th>
                        <th width="60">是否菜单</th>
                        <th width="120">是否验证</th>

                        <th width="120">名称</th>
                        <th>标识</th>
                    </tr>
                    </thead>
                    <tbody>
                    {volist name="nodeList.data" id='v'}
                    <tr>
                        <td align="center" valign="middle">
                            {switch name="$v.status"}
                            {case value="1"}
                            <span class="layui-badge layui-bg-green">正常</span>
                            {/case}
                            {default/}
                            <span class="layui-badge">异常</span>
                            {/switch}
                        </td>
                        <td align="center" valign="middle">
                            {switch name="$v.is_view"}
                            {case value="1"}
                            <span class="layui-badge layui-bg-green">是</span>
                            {/case}
                            {default/}
                            <span class="layui-badge">否</span>
                            {/switch}
                        </td>
                        <td align="center" valign="middle">
                            <input type="checkbox" value="{$v.id}" menu-url="{:url('admin/system.menu/add')}" data-url="{:url('admin/system.node/ismenu')}"  name="is_menu" lay-filter="isMenu" lay-skin="switch" lay-text="是|否" {eq name="$v.is_menu" value="1" }checked{/eq}>
                        </td>
                        <td align="center" valign="middle">
                            <input type="checkbox" value="{$v.id}"  data-url="{:url('admin/system.node/auth')}"  name="auth" lay-filter="auth" lay-skin="switch" lay-text="是|否" {eq name="$v.auth" value="1" }checked{/eq}>
                        </td>
                        <td>
                            <p class="nodeTitle">{$v.title}</p>
                        </td>
                        <td>{$v.name}</td>
                    </tr>
                    {/volist}
                    </tbody>
                </table>
            </form>
            {$nodePate|raw}
        </div>

    </div>
</div>